<%@ page language="java" pageEncoding="utf-8"%>

<!--/*** sumo CSS样式 修改**/-->
<style>
    .SumoSelect {width: 220px;height: 27px;color: rgb(65, 137, 203);font-size: 13px;}
    .SumoSelect label {font-size: 13px;}
    .SumoSelect span {font-size: 13px;}
    .SumoSelect > p {height: 27px;}
    .SumoSelect .select-all {height: 36px;}
</style>


<!--/*** 控件HTML标签 **/-->
<div class="col-md-12" style="margin-top:10px;padding: 0 0 0 5px;">
    <div class="col-md-3" style="padding: 0;">
        <label style="color: rgb(65, 137, 203);font-size: 12px;padding: 0px;margin: 0px;">子设备:</label>
    </div>
    <div class="col-md-9">
        <select id="toolSubIdSumo" multiple="multiple"></select>
    </div>
</div>



<script>
//    $(document).ready(function () {
        $("#toolSubIdSumo").SumoSelect({
            search: true,
            searchText: 'Enter here.',
            captionFormat: '已选择：{0}(项)',
            selectAll:true,
            captionFormatAllSelected: "全选",
            okCancelInMulti: true,
            locale :  ['确定', '取消', '全选'],
            isClickAwayOk: true,
        });


        function iniToolSubIdInfoFnc(){
            var inTrxObj = {
                fab_id       : $.trim($("#fabIdSumo").val()),
                bay_id       : $.trim($("#bayIdSumo").val()),
                ope_id       : $.trim($("#opeIdSumo").val()),
                toolg_id     : $.trim($("#toolgIdSumo").val()),
                root_tool_id : $.trim($("#toolMainIdSumo").val()),
                //tool_type    : 'SUB',
                spc_flg      : 'Y'
            };
            comAddSelectValueFnc("#toolSubIdSumo","TOOL", inTrxObj,false,false);
            $('#toolSubIdSumo')[0].sumo.reload();
        };
        iniToolSubIdInfoFnc();
        $("#fabIdSumo").change(iniToolSubIdInfoFnc);
        $("#bayIdSumo").change(iniToolSubIdInfoFnc);
        $("#opeIdSumo").change(iniToolSubIdInfoFnc);
        $("#toolgIdSumo").change(iniToolSubIdInfoFnc);
        $("#toolTypeRadio input[type=radio][name=toolType]").change(iniToolSubIdInfoFnc);
        $("#toolMainIdSumo").change(iniToolSubIdInfoFnc);
//    });
</script>